package com.czxy.demo01;

import java.util.Scanner;

public class Test01 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        System.out.println("请输入一个整数");
        int a = sc.nextInt();
        if (a%3==0&&a%5==0&&a%7==0){
            System.out.println("能同时被3,5,7整除");
        }else if (a%3==0&&a%5==0){
            System.out.println("能同时被3,5整除");
        }else if(a%3==0&&a%7==0){
            System.out.println("能同时被3,7整除");
        }else if(a%5==0&&a%7==0){
            System.out.println("能同时被5,7整除");
        } else if (a%3==0) {
            System.out.println("能被3整除");
        }else if (a%5==0){
            System.out.println("能被5整除");
        }else if (a%7==0){
            System.out.println("能被7整除");
        }else {
            System.out.println("不能同时被3,5,7任何一个整除");
        }
    }
}
